#coding=utf-8
'''
Created on 2016年3 15日
@author: wangpeng
'''
import ConfigParser
from nt import kill

Configpath = r'E:\eclipse\huawei_rader\all_mobile\common\configuration.txt'

def choose_ble():                       #设备IP地址
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("choose_BLE_device", "key_xpath")
        return current

def GetImagePath():                         #report保存路径
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("reportPath", "key")
        return current


def wendu():                         #report保存路径
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("menu_temp", "key_id")
        return current  
    
def BLE_disconnect():                         #出错的提示
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("menu_disconnect", "key_id")
        return current  

def adb_log():
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("adb_log", "key")
        return current
    
def choose_IR_tv():
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("IR_TV", "key_tv")
        #0为port号，rate为速率
        return current

def choose_IR_STB():
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("IR_STB", "key_STB")

        return current

def choose_IR_kongtiao():
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("IR_kongtiao", "key_kongtiao")

        return current

def choose_IR_jinghuaqi():
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("IR_jinghuaqi", "key_jinghuaqi")
        return current    

def click_jinghuaqi_key():
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("jinghuaqi_click", "click_first_key")
        return current    

def click_power_key():
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("IR_Power_key_ID", "key")
        #0为port号，rate为速率
        return current
    
def click_tv_power_key():
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("IR_Power_tv_ID", "tv_power_key")
        #0为port号，rate为速率
        return current

def click_kongtiao_power_key():
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("IR_Power_kongtiao_ID", "kongtiao_key")
        #0为port号，rate为速率
        return current

def choose_auto_RCU():
    #Configpath = r'E:\eclipse\huawei_rader\p8\common_5x\configuration.txt'
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("Auto_control_xpath", "choose_auto")
        return current
    
def huawei_BT_setting_icon_open():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("huawei_BT_setting_paired_icon", "icon_key")
        return current       
    
def kuwan_life_entry():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("kuwan_life_xpath", "choose_auto")
        return current  


def zhinengcotrol_choose():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("zhinengkongzhi_xpath", "choose_zhinengkongzhi")
        return current
       
def zhinengkognzhi_id_icon():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("zhinengkongzhi_icon_id", "key")
        return current


def dingshikongzhi_choose():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("dingshikongzhi_xpath", "choose_dingshi")
        return current 

def clock_choose():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("clock_xpath", "choose_clock")
        return current 

def device_mangement_entry():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("device_management_entry", "key")
        return current 

def device_management_choose():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("device_management_choose_id", "key")
        return current 

def device_click_ok():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("device_click_ok", "key")
        return current 

def setting_fujian():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("setting_menu_fujian", "key")
        return current 

def change_fujian():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("change_fujian_click_id", "key")
        return current 
    
def input_fujian_mac():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current_mac1 = Conf.get("input_fujian_mac_id", "mac1")
        current_mac2 = Conf.get("input_fujian_mac_id", "mac2")  
        current_mac3 = Conf.get("input_fujian_mac_id", "mac3")  
        current_mac4 = Conf.get("input_fujian_mac_id", "mac4")     
        current_mac5 = Conf.get("input_fujian_mac_id", "mac5")   
        current_mac6 = Conf.get("input_fujian_mac_id", "mac6")     
        return current_mac1,current_mac2,current_mac3,current_mac4,current_mac5,current_mac6

def click_fujian_connect():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("click_fujian_id", "key")
        return current 

def menu_setting_click():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("menu_setting_class_name", "key")    
        return current

def setting_menu_factory():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("setting_xiaoleidasetting", "key")    
        return current

def huifuchuchang_click():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("huifuchuchang_setting", "key")    
        return current

def setting_menu_guanyu():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("click_guanyu_xpath", "key")    
        return current

def click_menu_updage_xpath():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("click_menu_updage_xpath", "key")    
        return current

def click_BLE_update_xpath():
    with open(Configpath) as f:
        Conf = ConfigParser.ConfigParser()
        Conf.readfp(f)
        current = Conf.get("click_BLE_update_xpath", "key")    
        return current
    



